-- GENERATED SPELL FOR [Fel Warden] --


function spell0_22273(pUnit, Event) --@Fireball,n/a--
pUnit:FullCastSpellOnTarget(14034,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_22273', 3000, 1)
end

function spell1_22273(pUnit, Event) --@Frost Nova,Self--
pUnit:FullCastSpellOnTarget(11831,pUnit)
pUnit:RegisterEvent('Sorts_22273', 8325, 1)
end

function spell2_22273(pUnit, Event) --@Summoned Demon,Self--
pUnit:FullCastSpellOnTarget(7741,pUnit)
pUnit:RegisterEvent('Sorts_22273', 632, 1)
end

function Sorts_22273(pUnit, Event)
local choix_sorts_22273 = math.random(0, 2)
if choix_sorts_22273 == 0 then
pUnit:RegisterEvent('spell0_22273', 1, 1)
end
if choix_sorts_22273 == 1 then
pUnit:RegisterEvent('spell1_22273', 1, 1)
end
if choix_sorts_22273 == 2 then
pUnit:RegisterEvent('spell2_22273', 1, 1)
end
end

function mob22273_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_22273', math.random(1500, 3000), 1)
end

function mob22273_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob22273_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob22273_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(22273, 1, 'mob22273_Action')
RegisterUnitEvent(22273, 2, 'mob22273_Leave')
RegisterUnitEvent(22273, 3, 'mob22273_Kill')
RegisterUnitEvent(22273, 4, 'mob22273_Die')
